﻿<%@ Page Language="C#" MasterPageFile="~/Admin/MasterPage.master" AutoEventWireup="true"
    CodeFile="SubCategory.aspx.cs" Inherits="Admin_SubCategory" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="Server">
    <asp:TextBox ID="txtTitle" CssClass="tieude" runat="server"></asp:TextBox>
    <asp:DropDownList runat="server" ID="ddlCategory">
    </asp:DropDownList>
    <asp:ImageButton ID="btnSearch" ImageUrl="" OnClick="btnSearch_OnClick" runat="server"
        Style="background-color: Transparent" />
    <asp:LinkButton CausesValidation="false" CssClass="blue" ID="btnSearchAll" OnClick="btnSearchAll_OnClick"
        runat="server"></asp:LinkButton>
    <asp:LinkButton ID="lbtDelete" OnClick="lbtDelete_Onclick" runat="server" OnClientClick="javascript: return confirm('Bạn có chắc là sẽ xóa dòng này?');"></asp:LinkButton>
    <asp:Literal ID="lb_error" runat="server"></asp:Literal>
    <asp:Repeater runat="server" ID="rptList" OnItemDataBound="rptList_OnItemDataBound"
        OnItemCommand="rptList_OnItemCommand">
        <HeaderTemplate>
            <tr>
                <td align="center" class="head">
                    <span>No </span>
                </td>
                <td align="center" class="head">
                    <asp:LinkButton ID="lbtNote" runat="server" CommandArgument="ASC" CommandName="sortName">Title</asp:LinkButton>
                </td>
                <td align="center" class="head" style="width: 52px;">
                    <asp:LinkButton ID="lbtCountry" runat="server" CommandArgument="ASC" CommandName="sortOrder">Order</asp:LinkButton>
                </td>
                <td align="center" class="head" style="width: 52px;">
                    <asp:LinkButton ID="LinkButton1" runat="server" CommandArgument="ASC" CommandName="sortCode">Mã</asp:LinkButton>
                </td>
                <td align="center" class="head">
                    <asp:LinkButton ID="LinkButton2" runat="server" CommandArgument="ASC" CommandName="sortCategory">Category</asp:LinkButton>
                </td>
                <td align="center" id="tdChildHeader" class="head" runat="server">
                    <a>Xem Danh mục con </a>
                </td>
                <td class="head" align="center">
                    <input id="checkall" onclick='CheckSelect(this.checked);' type="checkbox" name="checkall">
                </td>
            </tr>
        </HeaderTemplate>
        <ItemTemplate>
            <tr>
                <td style="text-align: center">
                    <asp:Literal ID="ltrNo" runat="server"></asp:Literal><asp:HiddenField ID="hidID"
                        runat="server" />
                </td>
                <td>
                    <a href="SubCategory.aspx?id=<%#Eval("SubCategoryID")%>">
                        <asp:Literal runat="server" ID="ltrName"></asp:Literal></a>
                </td>
                <td>
                    <asp:TextBox runat="server" ID="txtOrder" Width="50"></asp:TextBox>
                </td>
                <td>
                    <asp:Label runat="server" ID="lbl_code"></asp:Label>
                </td>
                <td>
                    <asp:Literal runat="server" ID="ltrParent"></asp:Literal>
                </td>
                <td id="tdChild" align="center" runat="server">
                    <asp:LinkButton runat="server" ID="lbtSubCat" Text="Xem danh mục con" CommandName="ViewSubcat"
                        CommandArgument='<%#Eval("SubCategoryID")%>'></asp:LinkButton>
                </td>
                <td style="text-align: center">
                    <input runat="server" onclick="select_change(this.form)" id="chkDelete" type="checkbox"
                        value='<%# DataBinder.Eval(Container.DataItem, "SubCategoryID") %>' name="delete" />
                </td>
            </tr>
        </ItemTemplate>
    </asp:Repeater>
    <PagerV2:PagerV2_8 ID="hyperlinkPager" runat="server" CompactModePageCount="5" GenerateFirstLastSection="true"
        OnCommand="pager_Command" GeneratePagerInfoSection="false" GenerateSmartShortCuts="false"
        GenerateHiddenHyperlinks="false" NormalModePageCount="5" />
    <asp:Button ID="btnSave" OnClick="btnSave_OnClick" runat="server" />&nbsp;&nbsp;<a
        href="javascript:history.go(-1)"><asp:Button ID="btnBack" runat="server" /></a>
</asp:Content>
